package com.ruoyi.webshop.domain;

import java.util.Date;
import java.util.List;

import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 采购订单对象 goods_purchase
 * 
 * @author ruoyi
 * @date 2024-03-17
 */
public class GoodsPurchase extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 订单主键#primary */
    private Long purchaseId;

    /** 供应商#foreign#supplier_info=supplier_id,supplier_name */
    @Excel(name = "供应商#foreign#supplier_info=supplier_id,supplier_name")
    private Long supplierId;

    /** 订单时间(后台 new Date()) */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "订单时间(后台 new Date())", width = 30, dateFormat = "yyyy-MM-dd")
    private Date purchaseDate;

    /** 编号(唯一) */
    @Excel(name = "编号(唯一)")
    private String purchaseSn;

    /** 说明 */
    @Excel(name = "说明")
    private String purchaseInfo;

    /** 合计总金额(先默认为0.0) */
    @Excel(name = "合计总金额(先默认为0.0)")
    private Long purchaseTotal;

    /** 订单状态 */
    @Excel(name = "订单状态")
//     0=草稿 , 1=申请 , 2=审批 , 3=异常 , 4=结束
    private Integer purchaseState;

    private String supplierName;

    private List<GoodsPurchaseDetail> goodsPurchaseDetailList;

    @Override
    public String toString() {
        return "GoodsPurchase{" +
                "purchaseId=" + purchaseId +
                ", supplierId=" + supplierId +
                ", purchaseDate=" + purchaseDate +
                ", purchaseSn='" + purchaseSn + '\'' +
                ", purchaseInfo='" + purchaseInfo + '\'' +
                ", purchaseTotal=" + purchaseTotal +
                ", purchaseState=" + purchaseState +
                ", supplierName='" + supplierName + '\'' +
                ", goodsPurchaseDetailList=" + goodsPurchaseDetailList +
                '}';
    }

    public List<GoodsPurchaseDetail> getGoodsPurchaseDetailList() {
        return goodsPurchaseDetailList;
    }



    public void setGoodsPurchaseDetailList(List<GoodsPurchaseDetail> goodsPurchaseDetailList) {
        this.goodsPurchaseDetailList = goodsPurchaseDetailList;
    }

    public void setPurchaseId(Long purchaseId)
    {
        this.purchaseId = purchaseId;
    }

    public Long getPurchaseId() 
    {
        return purchaseId;
    }
    public void setSupplierId(Long supplierId) 
    {
        this.supplierId = supplierId;
    }

    public Long getSupplierId() 
    {
        return supplierId;
    }
    public void setPurchaseDate(Date purchaseDate) 
    {
        this.purchaseDate = purchaseDate;
    }

    public Date getPurchaseDate() 
    {
        return purchaseDate;
    }
    public void setPurchaseSn(String purchaseSn) 
    {
        this.purchaseSn = purchaseSn;
    }

    public String getPurchaseSn() 
    {
        return purchaseSn;
    }
    public void setPurchaseInfo(String purchaseInfo) 
    {
        this.purchaseInfo = purchaseInfo;
    }

    public String getPurchaseInfo() 
    {
        return purchaseInfo;
    }
    public void setPurchaseTotal(Long purchaseTotal) 
    {
        this.purchaseTotal = purchaseTotal;
    }

    public Long getPurchaseTotal() 
    {
        return purchaseTotal;
    }
    public void setPurchaseState(Integer purchaseState) 
    {
        this.purchaseState = purchaseState;
    }

    public Integer getPurchaseState() 
    {
        return purchaseState;
    }

    public String getSupplierName() {
        return supplierName;
    }

    public void setSupplierName(String supplierName) {
        this.supplierName = supplierName;
    }

}
